package com.yanmaohu.yulia.bean;

/**
 * @author Bright Lee
 */
public final class ReturnsDataTypeReturnsType implements ReturnsType {

    private int beginIndex;
    private int endIndex;
    private DataType dataType;
    private LocatorIndication locatorIndication;
    private ResultCast resultCast;

    public ReturnsDataTypeReturnsType(int endIndex,
                                      DataType dataType,
                                      LocatorIndication locatorIndication,
                                      ResultCast resultCast) {
        this.beginIndex = dataType.getBeginIndex();
        this.endIndex = endIndex;
        this.dataType = dataType;
        this.locatorIndication = locatorIndication;
        this.resultCast = resultCast;
    }

    @Override
    public int getBeginIndex() {
        return beginIndex;
    }

    @Override
    public int getEndIndex() {
        return endIndex;
    }

    public DataType getDataType() {
        return dataType;
    }

    public LocatorIndication getLocatorIndication() {
        return locatorIndication;
    }

    public ResultCast getResultCast() {
        return resultCast;
    }

}
